const structureEvent = {
    objToSleep: function (params) {
        const { objID, to = false } = params
        let obj = Game.getObjectById(objID)
        try {
            if (obj) {
                obj.room.memory['structure'][obj.structureType][objID].isRuning = to
            } else {
                // 如果找不到，那就尝试修改房间
                Memory.rooms[objID]['info']['state'].isRuning = to
            }
        } catch (error) {
            console.log(`已达到设定时间，但唤醒${objID}失败`);
            console.log(error);
        }
    }
}
export default structureEvent